{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 1. Running ado.file\n",
    "```chartable``` generates a chart of primary regression results for a variable list, combined with a table detailing those results."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [],
   "source": [
    "qui do \"https://raw.githubusercontent.com/SaoriIwa/Stata-IE-Visual-Library/master/Library/Charts/Chart%20of%20marginal%20effect%20with%20results%20table/chartable.ado\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 2. Uploading data"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [],
   "source": [
    "use \"https://github.com/SaoriIwa/Stata-IE-Visual-Library/raw/master/Library/Charts/Chart%20of%20marginal%20effect%20with%20results%20table/data.dta\", clear"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 3. Creating the graph"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "(0 observations deleted)\n"
     ]
    }
   ],
   "source": [
    "chartable ??_correct refer med_any med_class_any_6 med_class_any_16 ///\n",
    "\t, xsize(8) rhs(facility_private i.case_code) command(logit) or p case0(Public) case1(Private)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 5. Exporting the graph"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [],
   "source": [
    "qui graph export \"figure.png\" , replace width(2000)"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Stata",
   "language": "stata",
   "name": "stata"
  },
  "language_info": {
   "file_extension": ".do",
   "mimetype": "text/x-stata",
   "name": "stata"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
